package bill.study.javaPuzzlers.classy;

/**
 * This is no dynamic dispatch on static methods. When a program calls a static
 * method, the method to be invoked is selected at compile time., based on the
 * compile time type of the qualifier.
 * 
 * Static methods cannot be overriden, they can only be hidden.
 * 
 * @author yangliu
 * 
 */
class Dogg {
	public static void bark() {
		System.out.println("Woof ");
	}
}

class Basenji extends Dogg {
	public static void bark() {

	}
}

public class Bark {
	public static void main(String arg[]) {
		Dogg woofer = new Dogg();
		Dogg nipper = new Basenji();
		woofer.bark();
		nipper.bark();
	}

}
